<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="TemplateAddEdit.ascx.cs" Inherits="IGlobalist.Cms.Admin.Control.TemplateAddEdit" %>
<%@ Register Src="CmsExtPropertiesForm.ascx" TagName="CmsExtPropertiesForm" TagPrefix="uc1" %>

<table>
    <tr>
        <th colspan="2" align="center">
            <asp:Label runat="server" ID="lblStatus" ForeColor="#1A5688" Font-Bold="True" Font-Size="Medium"/>
        </th>        
    </tr>
    <tr>
        <td align="left">
            <asp:ValidationSummary ID="ValidationSummary1" runat="server" ShowMessageBox="True" />
        </td>
    </tr>
    
    <tr>
    <td colspan="2">
     <fieldset id="Fieldset2" runat="server">
         <legend><asp:Label ID="Label10"  runat="server"  Text="Product info" ></asp:Label> </legend>         
         <table>
                 <tr>
                    <td >
                        Template class 
                    </td>
                    <td>
                        <asp:DropDownList ID="ddlClassPage" runat="server" AutoPostBack="true"  Enabled="False" OnSelectedIndexChanged="ddlClassPage_SelectedIndexChanged" DataSourceID="ODSClassPage" DataTextField="Name" DataValueField="ID" >
                        </asp:DropDownList>
                        <asp:ObjectDataSource ID="ODSClassPage" runat="server" SelectMethod="GetClassListByClassTypeID"  TypeName="IGlobalist.Cms.Bll.ClassController">
                            <SelectParameters>
                                    <asp:Parameter DefaultValue="10" Name="classTypeID" Type="Int16" />
                            </SelectParameters>
                        </asp:ObjectDataSource>
                    </td>
                </tr>
                <tr>
                    <td>Name</td>
                    <td><asp:TextBox runat="server" ID="tbName" /><asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="tbName"
                ErrorMessage="Require Name" >*</asp:RequiredFieldValidator></td>
                </tr>
                 <tr>
                    <td>Description</td>
                    <td><asp:TextBox runat="server" ID="tbDescription" /></td>
                </tr>
                <tr>
                    <td>Type</td>
                    <td><asp:DropDownList runat="server" ID="ddlType" DataSourceID="XmlDSTemplateType" DataTextField="type" DataValueField="value" /><asp:XmlDataSource
                            ID="XmlDSTemplateType" runat="server" DataFile="~/Admin/XML/TemplateType.xml"></asp:XmlDataSource>
                    </td>
                </tr>
                <tr>
                    <td valign="top">
                        Template content
                        <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="tbContent"
                ErrorMessage="Require Content" >*</asp:RequiredFieldValidator>    
                    </td>
                    <td>
                        <asp:TextBox runat="server" ID="tbContent" TextMode="MultiLine"  Height="900px" Width="500px"/>                        
                    </td>
                </tr>         
         </table>
    </fieldset>
    </td>    
    </tr>  
    <tr  >
    <td colspan="2">
      <fieldset id="fsExt" runat="server" visible="false">
            <legend><asp:Label ID="lblExt"  runat="server"  Text="Ext Properties"></asp:Label> </legend>
        <uc1:CmsExtPropertiesForm ID="ucCmsExtPropertiesForm" runat="server"/>
       </fieldset>     
    </td>
    </tr>
</table>


